upload (FTP) |
This Web service operation is used to upload a file.
SOAP Request
<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP:Body>
<upload xmlns="http://schemas.cordys.com/ftpconnector/1.1">
<configuration>ftpserver</configuration>
<synchronous>true</synchronous>
<notification-subject>FTP</notification-subject>
<files>
<file type="ascii">
<source>\tempdocs\readme.txt</source>
<target>/readme.txt</target>
</file>
</files>
</upload>
</SOAP:Body>
</SOAP:Envelope>
<SOAP:Envelope xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <SOAP:Body> <upload xmlns="http://schemas.cordys.com/ftpconnector/1.1"> <configuration>ftpserver</configuration> <synchronous>true</synchronous> <notification-subject>FTP</notification-subject> <files> <file type="ascii"> <source>\tempdocs\readme.txt</source> <target>/readme.txt</target> </file> </files> </upload> </SOAP:Body> </SOAP:Envelope>
Request Parameters
Parameter |
Description |
---|---|
configuration |
Name of the Configuration Profile that contains the FTP server details. |
synchronous |
Specifies if the response must be intimated to the client. This can hold the following values:
|
notification-subject |
Notification subject on which the user has to subscribe to the Event service, to obtain the status of the request. |
files |
The files to be uploaded. |
file |
Details of each file. The type attribute here specifies the type of file to upload (ascii or binary).
|
source |
The name or path of the file to be uploaded, relative to the Base Directory specified in the FTP configuration. This tag is used while uploading a file from a specified source. |
target |
The path and the name of the file which must be uploaded to the FTP server. |
SOAP Response
<uploadResponse xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<configuration xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">ftpserver</configuration>
<notification-subject
xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">FTP</notification-subject>
<files xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<file type="ascii"
xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
<source>\tempdocs\readme.txt</source>
<target>/readme.txt</target>
<statuscode
xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">226</statuscode>
<status xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">Transfer complete. </status>
</file>
</files>
</uploadResponse>
<uploadResponse xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <configuration xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">ftpserver</configuration> <notification-subject xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">FTP</notification-subject> <files xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <file type="ascii" xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/"> <source>\tempdocs\readme.txt</source> <target>/readme.txt</target> <statuscode xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">226</statuscode> <status xmlns="http://schemas.cordys.com/ftpconnector/1.1" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">Transfer complete. </status> </file> </files> </uploadResponse>